home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Toolbox / Visual Basic Toolbox (P.I.E.)(1996).ISO / tpascal / bpvbx / form1.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1994-08-24  |  10.5 KB  |  376 lines

  1. VERSION 2.00
  2. Begin Form Form1 
  3.    BackColor       =   &H00C0C0C0&
  4.    Caption         =   "Disk Tool 1.0"
  5.    ClientHeight    =   3756
  6.    ClientLeft      =   1404
  7.    ClientTop       =   2832
  8.    ClientWidth     =   7260
  9.    Height          =   4344
  10.    HelpContextID   =   1
  11.    Left            =   1272
  12.    LinkTopic       =   "Form1"
  13.    ScaleHeight     =   3756
  14.    ScaleWidth      =   7260
  15.    Top             =   2376
  16.    Width           =   7524
  17.    Begin ThunderDiskTool DiskTool1 
  18.       BytesPerCluster =   0
  19.       BytesPerSector  =   0
  20.       ClustersAvailable=   0
  21.       Date            =   ""
  22.       DiskCapacity    =   0
  23.       DiskType        =   ""
  24.       DiskVerify      =   0   'False
  25.       Drive           =   ""
  26.       FreeSpace       =   0
  27.       Left            =   1680
  28.       Prop6           =   ""
  29.       SectorsPerCluster=   0
  30.       Size            =   0
  31.       Status          =   0
  32.       Time            =   ""
  33.       Top             =   240
  34.       TotalClusters   =   0
  35.       Volume          =   ""
  36.    End
  37.    Begin TextBox Text18 
  38.       Height          =   285
  39.       Left            =   4395
  40.       TabIndex        =   33
  41.       Top             =   240
  42.       Width           =   1695
  43.    End
  44.    Begin CommandButton Command2 
  45.       Caption         =   "E&xit"
  46.       Default         =   -1  'True
  47.       Height          =   375
  48.       Left            =   840
  49.       TabIndex        =   32
  50.       Top             =   3135
  51.       Width           =   1335
  52.    End
  53.    Begin TextBox Text17 
  54.       Height          =   285
  55.       Left            =   6300
  56.       TabIndex        =   31
  57.       Top             =   3240
  58.       Width           =   735
  59.    End
  60.    Begin TextBox Text16 
  61.       Height          =   285
  62.       Left            =   6300
  63.       TabIndex        =   30
  64.       Top             =   2865
  65.       Width           =   735
  66.    End
  67.    Begin TextBox Text15 
  68.       Height          =   285
  69.       Left            =   6300
  70.       TabIndex        =   29
  71.       Top             =   2490
  72.       Width           =   735
  73.    End
  74.    Begin TextBox Text14 
  75.       Height          =   285
  76.       Left            =   4425
  77.       TabIndex        =   27
  78.       Top             =   3240
  79.       Width           =   1695
  80.    End
  81.    Begin TextBox Text13 
  82.       Height          =   285
  83.       Left            =   4425
  84.       TabIndex        =   1
  85.       Top             =   2865
  86.       Width           =   1695
  87.    End
  88.    Begin TextBox Text12 
  89.       Height          =   285
  90.       Left            =   4425
  91.       TabIndex        =   6
  92.       Top             =   2490
  93.       Width           =   1695
  94.    End
  95.    Begin TextBox Text11 
  96.       Height          =   285
  97.       Left            =   4425
  98.       TabIndex        =   26
  99.       Top             =   2115
  100.       Width           =   1695
  101.    End
  102.    Begin TextBox Text10 
  103.       Height          =   285
  104.       Left            =   4425
  105.       TabIndex        =   18
  106.       Top             =   1740
  107.       Width           =   1695
  108.    End
  109.    Begin TextBox Text9 
  110.       Height          =   285
  111.       Left            =   4425
  112.       TabIndex        =   17
  113.       Top             =   1365
  114.       Width           =   1695
  115.    End
  116.    Begin TextBox Text8 
  117.       Height          =   285
  118.       Left            =   4425
  119.       TabIndex        =   16
  120.       Top             =   990
  121.       Width           =   1695
  122.    End
  123.    Begin TextBox Text7 
  124.       Height          =   285
  125.       Left            =   4425
  126.       TabIndex        =   15
  127.       Top             =   615
  128.       Width           =   1695
  129.    End
  130.    Begin TextBox Text6 
  131.       Height          =   285
  132.       Left            =   915
  133.       TabIndex        =   13
  134.       Top             =   2115
  135.       Width           =   1335
  136.    End
  137.    Begin TextBox Text5 
  138.       Height          =   285
  139.       Left            =   915
  140.       TabIndex        =   11
  141.       Top             =   1740
  142.       Width           =   1335
  143.    End
  144.    Begin TextBox Text4 
  145.       Height          =   285
  146.       Left            =   915
  147.       TabIndex        =   8
  148.       Top             =   1365
  149.       Width           =   1335
  150.    End
  151.    Begin TextBox Text3 
  152.       Height          =   285
  153.       Left            =   915
  154.       TabIndex        =   7
  155.       Top             =   990
  156.       Width           =   1335
  157.    End
  158.    Begin TextBox Text2 
  159.       Height          =   285
  160.       Left            =   960
  161.       TabIndex        =   3
  162.       Text            =   "A"
  163.       Top             =   240
  164.       Width           =   495
  165.    End
  166.    Begin CommandButton Command1 
  167.       Caption         =   "&Examine"
  168.       Height          =   375
  169.       Left            =   840
  170.       TabIndex        =   2
  171.       Top             =   2640
  172.       Width           =   1335
  173.    End
  174.    Begin TextBox Text1 
  175.       Height          =   285
  176.       Left            =   915
  177.       TabIndex        =   0
  178.       Top             =   615
  179.       Width           =   1335
  180.    End
  181.    Begin Label Label15 
  182.       BackColor       =   &H00C0C0C0&
  183.       Caption         =   "Disk Type"
  184.       ForeColor       =   &H00404080&
  185.       Height          =   255
  186.       Left            =   2400
  187.       TabIndex        =   34
  188.       Top             =   240
  189.       Width           =   1815
  190.    End
  191.    Begin Label Label14 
  192.       BackColor       =   &H00C0C0C0&
  193.       Caption         =   "Used Space"
  194.       ForeColor       =   &H00404080&
  195.       Height          =   255
  196.       Left            =   2430
  197.       TabIndex        =   28
  198.       Top             =   3240
  199.       Width           =   1815
  200.    End
  201.    Begin Label Label13 
  202.       BackColor       =   &H00C0C0C0&
  203.       Caption         =   "Free Space"
  204.       ForeColor       =   &H00404080&
  205.       Height          =   255
  206.       Left            =   2430
  207.       TabIndex        =   25
  208.       Top             =   2865
  209.       Width           =   1815
  210.    End
  211.    Begin Label Label4 
  212.       BackColor       =   &H00C0C0C0&
  213.       Caption         =   "Disk Capacity"
  214.       ForeColor       =   &H00404080&
  215.       Height          =   255
  216.       Left            =   2430
  217.       TabIndex        =   24
  218.       Top             =   2490
  219.       Width           =   1815
  220.    End
  221.    Begin Label Label1 
  222.       BackColor       =   &H00C0C0C0&
  223.       Caption         =   "Bytes Per Cluster"
  224.       ForeColor       =   &H00404080&
  225.       Height          =   255
  226.       Left            =   2430
  227.       TabIndex        =   23
  228.       Top             =   2115
  229.       Width           =   1815
  230.    End
  231.    Begin Label Label12 
  232.       BackColor       =   &H00C0C0C0&
  233.       Caption         =   "Sectors Per Cluster"
  234.       ForeColor       =   &H00404080&
  235.       Height          =   255
  236.       Left            =   2430
  237.       TabIndex        =   22
  238.       Top             =   1740
  239.       Width           =   1815
  240.    End
  241.    Begin Label Label11 
  242.       BackColor       =   &H00C0C0C0&
  243.       Caption         =   "Bytes Per Sector"
  244.       ForeColor       =   &H00404080&
  245.       Height          =   255
  246.       Left            =   2430
  247.       TabIndex        =   21
  248.       Top             =   1365
  249.       Width           =   1815
  250.    End
  251.    Begin Label Label10 
  252.       BackColor       =   &H00C0C0C0&
  253.       Caption         =   "Total Clusters"
  254.       ForeColor       =   &H00404080&
  255.       Height          =   255
  256.       Left            =   2430
  257.       TabIndex        =   20
  258.       Top             =   990
  259.       Width           =   1815
  260.    End
  261.    Begin Label Label9 
  262.       BackColor       =   &H00C0C0C0&
  263.       Caption         =   "Clusters Available"
  264.       ForeColor       =   &H00404080&
  265.       Height          =   255
  266.       Left            =   2430
  267.       TabIndex        =   19
  268.       Top             =   615
  269.       Width           =   1815
  270.    End
  271.    Begin Label Label8 
  272.       BackColor       =   &H00C0C0C0&
  273.       Caption         =   "Path"
  274.       ForeColor       =   &H00404080&
  275.       Height          =   255
  276.       Left            =   120
  277.       TabIndex        =   14
  278.       Top             =   2115
  279.       Width           =   615
  280.    End
  281.    Begin Label Label7 
  282.       BackColor       =   &H00C0C0C0&
  283.       Caption         =   "Time"
  284.       ForeColor       =   &H00404080&
  285.       Height          =   255
  286.       Left            =   120
  287.       TabIndex        =   12
  288.       Top             =   1740
  289.       Width           =   615
  290.    End
  291.    Begin Label Label6 
  292.       BackColor       =   &H00C0C0C0&
  293.       Caption         =   "Date"
  294.       ForeColor       =   &H00404080&
  295.       Height          =   255
  296.       Left            =   120
  297.       TabIndex        =   10
  298.       Top             =   1365
  299.       Width           =   615
  300.    End
  301.    Begin Label Label5 
  302.       BackColor       =   &H00C0C0C0&
  303.       Caption         =   "Size"
  304.       ForeColor       =   &H00404080&
  305.       Height          =   255
  306.       Left            =   120
  307.       TabIndex        =   9
  308.       Top             =   990
  309.       Width           =   615
  310.    End
  311.    Begin Label Label3 
  312.       BackColor       =   &H00C0C0C0&
  313.       Caption         =   "Volume"
  314.       ForeColor       =   &H00404080&
  315.       Height          =   255
  316.       Left            =   120
  317.       TabIndex        =   5
  318.       Top             =   615
  319.       Width           =   615
  320.    End
  321.    Begin Label Label2 
  322.       BackColor       =   &H00C0C0C0&
  323.       Caption         =   "Drive"
  324.       ForeColor       =   &H00404080&
  325.       Height          =   255
  326.       Left            =   120
  327.       TabIndex        =   4
  328.       Top             =   240
  329.       Width           =   615
  330.    End
  331. Option Explicit
  332. Sub clearText ()
  333.     text3 = ""
  334.     text4 = ""
  335.     text5 = ""
  336.     text6 = ""
  337.     text7 = ""
  338.     text8 = ""
  339.     text9 = ""
  340.     text10 = ""
  341.     text11 = ""
  342.     text12 = ""
  343.     text13 = ""
  344.     text14 = ""
  345.     text15 = ""
  346.     text16 = ""
  347.     text17 = ""
  348.     text18 = ""
  349. End Sub
  350. Sub Command1_Click ()
  351.     clearText
  352.     DiskTool1.Drive = text2.Text
  353.     DiskTool1.Action = 2
  354.     text18 = DiskTool1.DiskType
  355.     text1.Text = DiskTool1.Volume
  356.     text3 = DiskTool1.Size
  357.     text4 = DiskTool1.Date
  358.     text5 = DiskTool1.Time
  359.     text6 = DiskTool1.[Path String]
  360.     text7 = DiskTool1.ClustersAvailable
  361.     text8 = DiskTool1.TotalClusters
  362.     text9 = DiskTool1.BytesPerSector
  363.     text10 = DiskTool1.SectorsPerCluster
  364.     text11 = Val(DiskTool1.SectorsPerCluster) * Val(DiskTool1.BytesPerSector)
  365.     text12 = Val(DiskTool1.TotalClusters) * Val(text11)
  366.     text13 = Val(DiskTool1.ClustersAvailable) * Val(text11)
  367.     text14 = Val(text12) - Val(text13)
  368.     text15 = Str$(Int(Val(text12) / 1024)) & "K"
  369.     text16 = Str$(Val(text13) / 1024) & "K"
  370.     text17 = Str$(Val(text14) / 1024) & "K"
  371. End Sub
  372. Sub Command2_Click ()
  373.     Unload Me
  374.     End
  375. End Sub
  376.